[#escape x as x?html]
<!DOCTYPE html>
<html>
<head>
    [#include "/include/meta.ftl" /]
    [#include "/include/css.ftl" /]
    <title>附件列表</title>
    [#include "/include/js.ftl" /]
</head>
<body class="hold-transition skin-blue sidebar-mini">
<div class="wrapper">

    <div class="content-wrapper margin-left0">
        [#assign firstNavName="附件"]
        [#assign secondNavName="新增"]
        [#include "/include/contentHeader.ftl" /]

        <section class="content">
            <div class="box box-success">
                <form id="form" action="save" method="post" class="form-horizontal">
                    <input type="hidden" name="fileId" id="fileId">
                    <input type="hidden" name="originName" value="default">

                    <div class="box-body">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">名称</label>
                            <div class="col-sm-6">
                                <input type="text" name="name" class="form-control" placeholder="名称">
                            </div>
                        </div>
                    </div>

                    <div class="box-body">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">分类</label>
                            <div class="col-sm-6">
                                <div class="checkbox">
                                    [#list fileClasses as fileClass]
                                        <label>
                                            <input name="fileClassId" type="radio" value="${fileClass.id}">
                                        ${fileClass.name}
                                        </label>
                                    [/#list]
                                </div>
                            [#--<div class="checkbox">
                                                         <label>
                                                             <input type="checkbox" disabled="">
                                                             Checkbox disabled
                                                         </label>
                                                     </div>--]
                            </div>
                        </div>
                    </div>

                    <div class="box-body">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">文件</label>
                            <div class="col-sm-6" id="uploadFile">
                                <input type="file" name="file" id="file">
                            </div>
                        </div>
                    </div>

                    <div class="box-body">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">是否显示</label>
                            <div class="col-sm-6">
                                <div class="radio">
                                    <label>
                                        <input type="radio" name="display" value="true" checked="">是
                                    </label>
                                    &nbsp;&nbsp;
                                    <label>
                                        <input type="radio" name="display" value="false">否
                                    </label>
                                </div>
                            </div>
                        </div>
                    </div>

                    <div class="box-body">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">是否置顶</label>
                            <div class="col-sm-6">
                                <div class="radio">
                                    <label>
                                        <input type="radio" name="top" value="true">是
                                    </label>
                                    &nbsp;&nbsp;
                                    <label>
                                        <input type="radio" name="top" value="false" checked="">否
                                    </label>
                                </div>
                            </div>
                        </div>
                    </div>

                    <div class="box-footer">
                        <div class="row">
                            <div class="col-sm-offset-2">
                                <button id="btnSubmit"  type="button" class="btn btn-primary">保存</button>
                            </div>
                        </div>
                    </div>
                </form>
            </div>
        </section>
    </div>

</div>
<!-- ./wrapper -->
<script type="text/javascript">
    require([ 'admin/js/file/add' ], function(Page) {
        Page.main();
    });
</script>
</body>
</html>
[/#escape]
